import common from './common'
import paths from './paths'

const sqlService = {};

(function (service) {
    service.pageQuery = (sqlParam) => {
        return common.post(paths.sql.pageQuery, null, sqlParam)
    }

    service.listQuery = ({ params, data }) => {
      return common.post(paths.sql.listQuery, params, data)
    }

    service.firstQuery = (data) => {
      return common.post(paths.sql.firstQuery, null, data)
    }

    service.listAllSqlConfig = (sqlParam) => {
      return common.post(paths.sql.listAllSqlConfig, null, sqlParam)
    }
})(sqlService)

export default sqlService
